import {RouteObject} from "react-router-dom";

//导入页面规则
interface PageRule {
    (): void
}

//meta规则
interface MetaRule {
    auth ?: boolean,
    title ?: string,
    [name:string] : any
}

//单个路由规则
interface RouteObjectRule extends RouteObject {
    children ?: RouteObjectRule[], //子路由
    page ?: PageRule, //route导入页面的对象
    path ?: string, //页面路径
    redirect ?: string, //重定向地址
    meta ?: MetaRule, //页面参数
}

export default RouteObjectRule;
